package com.ddwl.funds.dao;

import com.ddwl.common.dao.TkDao;
import com.ddwl.funds.dao.mapper.WxPayConfigMapper;
import com.ddwl.funds.dao.model.WxPaymentConfig;
import org.springframework.stereotype.Repository;

/**
 * 微信支付配置表(WxPayConfig)数据处理
 *
 * @author zach
 * @since 2020-09-26 14:43:41
 */
@Repository
public class WxPayConfigDao extends TkDao<WxPayConfigMapper, WxPaymentConfig> {


    public WxPaymentConfig getWxPayServerByProduct(String product){
        WxPaymentConfig query = new WxPaymentConfig();
        query.setProduct(product);
        return selectOne(query);
    }

    public WxPaymentConfig getWxPayServerByAppId(String appId){
        WxPaymentConfig query = new WxPaymentConfig();
        query.setAppId(appId);
        return selectOne(query);
    }
}